<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<link rel="stylesheet" type="text/css" href="res/layui/css/layui.css">
<link rel="stylesheet" type="text/css" href="res/css/main.css">
<link rel="stylesheet" href="res/css/index.css">
<title>赛程安排</title>
<style>
	.select{
		font-size:24px;
		text-align:center;
	}
</style>
</head>
<body>

	<!-- 导入导航栏 -->
	<div class="layui-container" style="width:100%">
	  	<%@ include file="header.jsp" %> 
  	</div>
  	
  	<div class="layui-container all"></div>
	  <div class="layui-container lower">
		    <div class="layui-row layui-col-space12">
		    	<p class="select">${param.professionalname}专业赛事成绩统计</p>
				<table id="demo" lay-filter="test" lay-skin="nob"></table>			   	
			</div>
		</div>
		
		
		<input  type="hidden" name="professionalid" id="professionalid" value="${param.professionalid }">
  	<!-- footer部分 -->
	<div class="layui-container" style="width:100%;margin-top:10px;">
	  	<%@ include file="footer.jsp" %> 
  	</div>
<script src="res/layui/layui.js"></script>
</body>
<script>
layui.use(['table','jquery'], function(){
  var table = layui.table;
  var $ = layui.jquery;

  	 var id = $("#professionalid").val();

 
  //第一个实例
  table.render({
    elem: '#demo'
    ,height: '800px'
    ,url: 'professionalstatistics.action?professionalid=' + id//数据接口
    ,page: true //开启分页
    ,limits: [50,100,150]
     ,limit: 50 //每页默认显示的数量
     ,even:true
    ,cols: [[ //表头
      {field: 'athletesname', title: '姓名'}
      ,{field: 'classname', title: '班级',width:200}
      ,{field: 'projectname', title: '项目'}
      ,{field: 'itemcategory', title: '项目类别',templet:function(d){
	    		 return d.itemcategory == "1" ? "个人赛" : "集体赛"}}
      ,{field: 'agendtype', title: '项目组别',templet:function(d){
	    		 return d.agendtype == "1" ? "男子组" : "女子组"}}
      ,{field: 'finalresult', title: '成绩'}
      ,{field: 'finalrank', title: '名次'}
 
    ]]
  });
  
});
</script>

</html>